package com.aust.lambda;

import java.util.concurrent.Callable;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

public class TestLambda7 {
    public static void main(String[] args) throws Exception {
        Callable<Boolean> helloWorld = new Callable<>() {
            @Override
            public Boolean call() throws Exception {
                System.out.println("Hello World");
                return true;
            }
        };
        ExecutorService executorService = Executors.newFixedThreadPool(1);
        executorService.submit(helloWorld);
        executorService.shutdown();
    }
}
